
package com.attendancesystem.model;
/**
 * 系统管理员实体类
 * 对应数据库表：administrators
 */
public class Admin {
    // 管理员ID（主键）
    private String adminId;

    // 登录账号（唯一）
    private String username;

    // 加密密码
    private String password;

    // 管理员姓名
    private String fullName;

    // 管辖部门
    private String department;

    // 联系电话
    private String contactPhone;

    // 电子邮箱
    private String email;

    // 办公室地址
    private String office;

    // 无参构造函数
    public Admin() {
    }

    // 全参构造函数
    public Admin(String adminId, String username, String password,
                         String fullName, String department, String contactPhone,
                         String email, String office) {
        this.adminId = adminId;
        this.username = username;
        this.password = password;
        this.fullName = fullName;
        this.department = department;
        this.contactPhone = contactPhone;
        this.email = email;
        this.office = office;
    }

    // Getter & Setter 方法
    public String getAdminId() {
        return adminId;
    }

    public void setAdminId(String adminId) {
        this.adminId = adminId;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getFullName() {
        return fullName;
    }

    public void setFullName(String fullName) {
        this.fullName = fullName;
    }

    public String getDepartment() {
        return department;
    }

    public void setDepartment(String department) {
        this.department = department;
    }

    public String getContactPhone() {
        return contactPhone;
    }

    public void setContactPhone(String contactPhone) {
        this.contactPhone = contactPhone;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getOffice() {
        return office;
    }

    public void setOffice(String office) {
        this.office = office;
    }

    @Override
    public String toString() {
        return "Administrator{" +
                "adminId='" + adminId + '\'' +
                ", username='" + username + '\'' +
                ", password='[PROTECTED]'" +
                ", fullName='" + fullName + '\'' +
                ", department='" + department + '\'' +
                ", contactPhone='" + contactPhone + '\'' +
                ", email='" + email + '\'' +
                ", office='" + office + '\'' +
                '}';
    }
}

